import request from '@/utils/request'

export function getBoolData(order_id) {
  return request({
    url: 'backend_get_bool_data',
    method: 'post',
    params: { order_id: order_id }
  })
}

export function getTongdunData(order_id) {
  return request({
    url: 'backend_get_tongdun_data',
    method: 'post',
    params: { order_id: order_id }
  })
}
// 获取订单
export function fetchAllListByDay(query) {
  return request({
    url: '/order/getBackendOrderListByDay',
    method: 'get',
    params: query
  })
}
// 获取征信PDF
export function downloadPdf(query) {
  return request({
    url: 'big_data_download',
    method: 'post',
    params: query
  })
}
// 获取订单
export function fetchAllListByMonth(query) {
  return request({
    url: '/order/getBackendOrderListByMonth',
    method: 'get',
    params: query
  })
}
export function fetchAllList(query) {
  return request({
    url: 'backend_order_list',
    method: 'get',
    params: query
  })
}
// 创建订单
export function createBackendOrder(data) {
  return request({
    url: 'backend_create_order',
    method: 'post',
    data
  })
}

export function acceptOrder(order_id) {
  return request({
    url: 'backend_order_accept',
    method: 'post',
    params: { order_id: order_id }
  })
}
export function UploadFileAdmin(data) {
  return request({
    url: 'backend_upload_order_file_admin',
    method: 'post',
    data
  })
}
export function getche300Data(data) {
  return request({
    url: 'backend_get_che300',
    method: 'post',
    data
  })
}
export function getSignUrl(data) {
  return request({
    url: 'esign_get_signurl',
    method: 'post',
    data
  })
}
export function deleteContract(data) {
  return request({
    url: 'delete_order_basic_contract',
    method: 'post',
    data
  })
}
export function getRequestFunds(data) {
  return request({
    url: 'backend_request_funds',
    method: 'post',
    data
  })
}
export function getOrderRecord(data) {
  return request({
    url: 'backend_get_order_record',
    method: 'post',
    data
  })
}
export function getImagesData(data) {
  return request({
    url: 'backend_get_che_images',
    method: 'post',
    data
  })
}
// 获取商户和销售列表
export function fetchMarchantAndSale() {
  return request({
    url: 'backend_merchant_and_sale',
    method: 'get'
  })
}

// 获取初审订单
export function getBackendFirstOrder(query) {
  return request({
    url: '/order/getBackendFirstOrder',
    method: 'get',
    params: query
  })
}

// 获取信审订单
export function getBackendLetterOrder(query) {
  return request({
    url: '/order/getBackendLetterOrder',
    method: 'get',
    params: query
  })
}
// 获取合同订单
export function getBackendSignOrder(query) {
  return request({
    url: '/order/getBackendSignOrder',
    method: 'get',
    params: query
  })
}
// 获取术后订单
export function getBackendOperationOrder(query) {
  return request({
    url: '/order/getBackendOperationOrder',
    method: 'get',
    params: query
  })
}
// 获取退款订单
export function getBackendRefundOrder(query) {
  return request({
    url: '/order/getBackendRefundOrder',
    method: 'get',
    params: query
  })
}
// 获取订单记录
export function fetchOrderRecordListByOrderId(query) {
  return request({
    url: '/order/getOrderRecordListByOrderId',
    method: 'get',
    params: query
  })
}
// 订单详情，包括订单记录
export function fetchOrderDetail(order_id) {
  return request({
    url: 'backend_order_detail',
    method: 'post',
    params: { order_id: order_id }
  })
}

// 提交审核
export function submitCheckStatus(data) {
  return request({
    url: 'backend_order_exadmin',
    method: 'post',
    data
  })
}
// 大数据下载
export function bigdataDownLoad(data) {
  return request({
    url: 'backend_big_data_pdf',
    method: 'post',
    data
  })
}
// 合同下载
export function downloadDocx(data) {
  return request({
    url: 'backend_download_docx',
    method: 'post',
    data
  })
}
// 下载合同
export function downloadEsignContract(data) {
  return request({
    url: './esign_download_signed_contract',
    method: 'post',
    data
  })
}
// 发起签署
export function applySign(data) {
  return request({
    url: './junziqian_index',
    method: 'post',
    data
  })
}
// 已完成导出
export function exceloutComplateList(data) {
  return request({
    url: 'backend_excel_complateList',
    method: 'post',
    data
  })
}
// 新增资料记录
export function createOrderDataRecord(data) {
  return request({
    url: 'backend_create_record',
    method: 'post',
    data
  })
}
// 订单资料记录
export function orderDataRecordList(data) {
  return request({
    url: 'backend_orderdata_record_list',
    method: 'post',
    data
  })
}
// 资料记录日志
export function orderDataRecordLog(data) {
  return request({
    url: 'backend_create_record_log',
    method: 'post',
    data
  })
}
// 资料记录导出
export function orderDataRecordExcelout(data) {
  return request({
    url: 'backend_order_data_excelout',
    method: 'post',
    data
  })
}
// 出资公司
export function getOwnerCompanyList(data) {
  return request({
    url: './backend_get_owner_company_list',
    method: 'post',
    data
  })
}
// 催签
export function CallingSignatures(data) {
  return request({
    url: './junziqian_tip_sign',
    method: 'post',
    data
  })
}
// 合同资料补录
export function returnContractDatarSubmit(data) {
  return request({
    url: 'backend_return_contract_datar_submit',
    method: 'post',
    data
  })
}
// 获取合同补录资料
export function contractDataAddDetail(data) {
  return request({
    url: 'backend_return_contract_datar_detail',
    method: 'post',
    data
  })
}
// 获取合同申请资料
export function contractApplyDetail(data) {
  return request({
    url: 'backend_return_apply_contract_detail',
    method: 'post',
    data
  })
}
// 获取当前合同
export function getOrcerContract(data) {
  return request({
    url: 'backend_get_orcer_contract_docx',
    method: 'post',
    data
  })
}
export function contractUpload(data) {
  return request({
    url: 'backend_contact_upload',
    method: 'post',
    data
  })
}
// 修改订单基本信息
export function editOrderMainInfo(data) {
  return request({
    url: 'backend_order_edit_main',
    method: 'post',
    data
  })
}
// 修改订单合同信息
export function editOrderHt(data) {
  return request({
    url: 'backend_order_edit_ht',
    method: 'post',
    data
  })
}
// 修改订单信审资料信息
export function editOrderLetter(data) {
  return request({
    url: 'backend_order_edit_letter',
    method: 'post',
    data
  })
}
// 修改订单合同资料备注
export function updateOrderDesc(data) {
  return request({
    url: '/order/updateOrderDesc',
    method: 'post',
    data
  })
}
// 百融风控大数据
export function getBaiRongData(data) {
  return request({
    url: 'backend_get_bairong_data',
    method: 'post',
    data
  })
}
// 术后
export function operationSubmit(data) {
  return request({
    url: '/order/operationSubmit',
    method: 'post',
    data
  })
}
// 备注订单客户信息
export function descOrderMain(data) {
  return request({
    url: 'backend_order_desc',
    method: 'post',
    data
  })
}
// 退回信审
export function backLetter(data) {
  return request({
    url: 'backend_order_back_to_letter',
    method: 'post',
    data
  })
}
// 备注订单联系人信息
export function descOrderLetter(data) {
  return request({
    url: '/order/descOrderLetter',
    method: 'post',
    data
  })
}
// 获取通过点拒绝点
export function getOrderPoint(data) {
  return request({
    url: 'backend_get_order_point',
    method: 'post',
    data
  })
}
// 获取订单
export function getBackendSignOrderAll(data) {
  return request({
    url: 'backend_sign_order_all',
    method: 'get',
    data
  })
}

